﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;

namespace WindowsFormsApplication3.Administracion.Empleados
{
    public partial class AgregarNuevoEmpleado : Form
    {
        public AgregarNuevoEmpleado()
        {
            InitializeComponent();
        }

        private void empleadoToolStripMenuItem_Click(object sender, EventArgs e)
        {

        }

        private void AgregarNuevoEmpleado_Load(object sender, EventArgs e)
        {
            lblMaxDireccion.Text = "Caracteres restantes: " + (txtDireccion.MaxLength - txtDireccion.Text.Length).ToString();
            lblMaxDistrito.Text = "Caracteres restantes: " + (txtbxDistrito.MaxLength - txtbxDistrito.Text.Length).ToString();
            lblMaxEmail.Text = "Caracteres restantes: " + (txtbxEmail.MaxLength - txtbxEmail.Text.Length).ToString();
            lblMaxApellido.Text = "Caracteres restantes: " + (txtbxApellido.MaxLength - txtbxApellido.Text.Length).ToString();
            lblMaxNombre.Text = "Caracteres restantes: " + (txtbxNombre.MaxLength - txtbxNombre.Text.Length).ToString();
            lblMaxRazon.Text = "Caracteres restantes: " + (txtbxRazon.MaxLength - txtbxRazon.Text.Length).ToString();
            lblMaxNotas.Text = "Caracteres restantes: " + (txtbxNotas.MaxLength - txtbxNotas.Text.Length).ToString();
        }

        private void txtDireccion_TextChanged(object sender, EventArgs e)
        {
            lblMaxDireccion.Text = "Caracteres restantes: "+(txtDireccion.MaxLength - txtDireccion.Text.Length).ToString() ;
        }

        private void txtbxDistrito_TextChanged(object sender, EventArgs e)
        {
            lblMaxDistrito.Text = "Caracteres restantes: " + (txtbxDistrito.MaxLength - txtbxDistrito.Text.Length).ToString();
        }


        private void txtbxApellido_TextChanged(object sender, EventArgs e)
        {
            lblMaxApellido.Text = "Caracteres restantes: " + (txtbxApellido.MaxLength - txtbxApellido.Text.Length).ToString();
        }

        private void txtbxNombre_TextChanged(object sender, EventArgs e)
        {
            lblMaxNombre.Text = "Caracteres restantes: " + (txtbxNombre.MaxLength - txtbxNombre.Text.Length).ToString();
        }

        private void txtbxEmail_TextChanged(object sender, EventArgs e)
        {
            lblMaxEmail.Text = "Caracteres restantes: " + (txtbxEmail.MaxLength - txtbxEmail.Text.Length).ToString();
        }

        private void txtbxNotas_TextChanged(object sender, EventArgs e)
        {
            lblMaxNotas.Text = "Caracteres restantes: " + (txtbxNotas.MaxLength - txtbxNotas.Text.Length).ToString();
        }

        private void txtbxRazon_TextChanged(object sender, EventArgs e)
        {
            lblMaxRazon.Text = "Caracteres restantes: " + (txtbxRazon.MaxLength - txtbxRazon.Text.Length).ToString();
        }
    }
}
